<!DOCTYPE html>
<html>

	<head>
		<meta charset="utf-8">
		<title>华胜集团</title>
		
		<meta http-equiv="Cache-Control" content="no-cache, no-store, must-revalidate" />
		<meta http-equiv="Pragma" content="no-cache" />
		<meta http-equiv="Expires" content="0" />
		<meta name="viewport" content="width=device-width,initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no, viewport-fit=cover">
		
		<meta name="apple-mobile-web-app-capable" content="yes">
		<meta name="apple-mobile-web-app-status-bar-style" content="black">
		<!--标准mui.css-->
		<link rel="stylesheet" href="css/unified.css" />
		<!--App自定义的css-->
	</head>

	<body>
<!-- ----------------------------底部选项卡 begin------------------------------> 
		<nav class="mui-bar mui-bar-tab foottab" id="botNav">
			<a id="defaultTab"  class="mui-tab-item mui-active" href="#tab-index">
				<span class="mui-icon iconfont   icon-shouye"></span>
				<span class="mui-tab-label">主页</span>
			</a>
			<a id="classTab" class="mui-tab-item" href="#tab-classify">
				<span class="mui-icon iconfont  icon-QRCode"> </span>
				<span class="mui-tab-label">产品分类</span>
			</a>
			<a id="cartTab" class="mui-tab-item" href="#tab-cart" >
				<span class="mui-icon iconfont  icon-cart"></span>
				<span class="mui-tab-label">购物车</span>
			</a>
			<a id="myTab" class="mui-tab-item" href="#tab-my" >
				<span class="mui-icon iconfont icon-account"></span>
				<span class="mui-tab-label">我</span>
			</a>
		</nav>
<!-- ----------------------------底部选项卡 end------------------------------> 

<!-- ----------------------------内容加载 end------------------------------> 
		<div class="mui-content">
			<div id="tab-index" class="mui-control-content mui-active">
				<iframe src="tab-index.html?v1111" name="indexname"  id="tabIndex"></iframe>
			</div>
			<div id="tab-classify" class="mui-control-content" >
				<iframe src="tab-classify.html" id="tabClassify"></iframe>
			</div>
			<div id="tab-cart" class="mui-control-content">
				<iframe src="tab-cart.html" id="tabCart"></iframe>
		
			</div>
			<div id="tab-my" class="mui-control-content">
				<iframe src="tab-my.html" id="tabMy"></iframe>
			</div>
		</div>
<!-- ----------------------------内容加载 end------------------------------> 
	</body>
	<script src="js/mui.min.js"></script>
	
	<script type="text/javascript" src="js/jquery-3.2.1.min.js" ></script>
	<!--<script src="js/Fn.js"></script>-->
	<!--<script src="js/login.js"></script>-->
	<script>document.write("<script type='text/javascript' src='js/Fn.js?v=" + Date.now() + "'><\/script>");</script>
	<script>
		
		mui.init({
			swipeBack:true //启用右滑关闭功能
		});

		$("#defaultTab").on('tap',function(){
			rloadurl("tab-index.html" , 'tabIndex');
		});
		
		$("#classTab").on('tap',function(){
			rloadurl("tab-classify.html" , 'tabClassify' );
		});	
//		$("#myTab").on('tap',function(){
//			rloadurl("tab-my.html" , 'tabMy' );
//		});
		function rloadurl(Url , itext){
			var thishref = document.getElementById(itext).contentWindow.location.href;
			if(thishref != URL_all+'mp/'+Url ) {
				document.getElementById(itext).contentWindow.location.href = URL_all+'mp/'+Url;
			}
		}
		
		$("#botNav > a").on('tap',function(){
//			var urlv=new Date().getTime();
			var urlname = "?tabType="+ $(this).index()+"&time="+new Date().getTime() ;
			history.pushState({}, {},urlname );

		})
		if(GetQueryString('tabType') ){
//			console.log('地址发生了变化')
			var index = GetQueryString('tabType');
			$("#botNav > a").not($("#botNav > a").eq(index).addClass('mui-active')).removeClass('mui-active') ;
			$(".mui-content > div").not($(".mui-content > div").eq(index).addClass('mui-active')).removeClass('mui-active') ;

		}

	</script>
</html>